package cn.bgs.serviceedu.service.impl;

import cn.bgs.serviceedu.entity.Orders;
import cn.bgs.serviceedu.dao.OrdersMapper;
import cn.bgs.serviceedu.service.OrdersService;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 订单表 服务实现类
 * </p>
 *
 * @author YiChen
 * @since 2021-10-20
 */
@Service
public class OrdersServiceImpl extends ServiceImpl<OrdersMapper, Orders> implements OrdersService {
    @Autowired
    private OrdersMapper ordersMapper;

    @Override
    public List<Orders> findAllList(QueryWrapper<Orders> wrapper) {

        return ordersMapper.findAllList(wrapper);
    }

    @Override
    public Orders findByIdOrders(String ordersId) {
        return ordersMapper.findByIdOrders(ordersId);
    }

    @Override
    public List<Orders> findByIdCustOrders(Integer customerId) {
        return ordersMapper.findByIdCustOrders(customerId);
    }
}
